/**
 *Copyright (c) 2024 watereyes
 * workflow is licensed under Mulan PubL v2.
 * You can use this software according to the terms and conditions of the Mulan
 * PubL v2.
 * You may obtain a copy of Mulan PubL v2 at:
 *          http://license.coscl.org.cn/MulanPubL-2.0
 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
 * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
 * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
 * See the Mulan PubL v2 for more details.
 */
package com.koron.workflow.baseConfig.bean;

import com.koron.workflow.common.bean.BaseBean;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.util.List;

/**
 * @author qingfeng
 * @description: TODO
 * @date 2020/4/13 10:32
 */
public class DepartmentBean extends BaseBean {

    @NotNull(message = "组织名称不能为空")
    @Size(max = 50, message = "组织名称最多能输入50个字符")
    private String name;

    public String getShortname() {
        return shortname;
    }

    public void setShortname(String shortname) {
        this.shortname = shortname;
    }

    @Size(max = 50, message = "简称最多能输入50个字符")
    private String shortname;

    @NotNull(message = "组织编码不能为空")
    @Size(max = 50, message = "组织编码最多能输入50个字符")
    private String code;

    @Size(max = 255, message = "组织描述最多能输入255个字符")
    private String description;

    @Size(max = 100, message = "分级编码最多能输入100个字符")
    private String classCode;

    private Integer sn;

    @Size(max = 11, message = "组织电话最多能输入11个字符")
    private String tel;

    @NotNull(message = "状态不能为空")
    @Range(min = 0, max = 1, message = "状态只能为0(停用)或1(启用)")
    private Integer state;
    
    private String stateName;

    private Integer flag;
    
    private Integer flagName;

    private String parentCode;

    private String parentmask;

    private List<DepartmentBean> children;
    
    public String getStateName() {
		return stateName;
	}

	public Integer getFlagName() {
		return flagName;
	}

	public void setStateName(String stateName) {
		this.stateName = stateName;
	}

	public void setFlagName(Integer flagName) {
		this.flagName = flagName;
	}

	public String getParentmask() {
        return parentmask;
    }

    public void setParentmask(String parentmask) {
        this.parentmask = parentmask;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getClassCode() {
        return classCode;
    }

    public void setClassCode(String classCode) {
        this.classCode = classCode;
    }

    public Integer getSn() {
        return sn;
    }

    public void setSn(Integer sn) {
        this.sn = sn;
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public Integer getFlag() {
        return flag;
    }

    public void setFlag(Integer flag) {
        this.flag = flag;
    }

    public String getParentCode() {
		return parentCode;
	}

	public void setParentCode(String parentCode) {
		this.parentCode = parentCode;
	}

	public List<DepartmentBean> getChildren() {
        return children;
    }

    public void setChildren(List<DepartmentBean> children) {
        this.children = children;
    }
}
